<!--<?php
$forumstr='';
$formustr_n=0;
foreach($cache_forums as $h_forum){
	if(intval($h_forum['pid'])==0){
		if(++$formustr_n>5){break;}
		$forumstr.="<li class=\"header_121_a\" id=\"hmenu_fid{$h_forum['id']}\"><a href=\"index.php?fid={$h_forum['id']}\">{$h_forum['forumname']}</a></li>";
	}
}
$tmp_str='';
foreach($cache_template as $tmp){
	$tmp_str.="<li><a href=\"index.php?styleid={$tmp['id']}\" style=\"color:{$tmp['color1']}\"><span style=\"background:{$tmp['color1']}; display:block; margin-top:11px; width:10px; height:10px; float:left; overflow:hidden;\"></span>{$tmp['name']}</a></li>";
}
$plugins_str='';
foreach($cache_plugins as $plg){
	$plugins_str.="<li><a href=\"{$plg[link]}\">{$plg['name']}</a></li>";
	$pluginscode.=$plg['code'];
}
if(!empty($cache_plugins)){
	$plugins_menu="<li class=\"header_121_a\" id=\"hmenu_plugins\" onmouseover=\"selectMenu(this.id)\"><a href=\"#\">插件</a></li>";
}

print <<<EOT
-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>{$headtitle}</title>
{$headmeta}
{$cache_settings['headcontent']}
<link href="{$_SYS['TP']}/css.php?t=templatecss&s={$_SYS['styleid']}&v={$_SYS['VERSION']}&f=global" rel="stylesheet" type="text/css" />
</head>
<body>
	<div class="header_top">
		<div class="div_out_onbg">
			<div class="header_top_left"><a href="search.php?action=new">今日新帖</a><a href="search.php?action=good">精华帖子</a></div>
			<div class="header_top_right">
			
<!--
EOT;
if(isLogin()){
print <<<EOT
-->
<a href="{$_SYS['indexurl']}">返回首页</a> | <a href="member.php">欢迎您: {$lg['displayname']}</a> | <a href="member.php?action=msg">站内短信</a> | <a href="member.php">个人中心</a> | <a href="logout.php">退出</a>
<!--
EOT;
if($lg['groupid']==GROUP_ADMIN){
print <<<EOT
-->
 | <a href="admin" target="_blank">后台管理</a>
<!--
EOT;
}
}else{
print <<<EOT
-->
<a href="{$_SYS['indexurl']}">返回首页</a> | <a href="login.php">会员登录</a> | <a href="{$cache_settings['signupfilename']}">会员注册</a>
<!--
EOT;
}
print <<<EOT
-->
			
			</div>
		</div>
	</div>

<div class="div_out_onbg">
<div class="header">
<table class="header_table"><tr><td class="header_table_left"><a href="{$_SYS['indexurl']}"><img src="{$_SYS['TP']}/images/bg_logo.png" border="0" /></a></td><td class="header_table_right"><div class="logoright">{$adcode[1]}</div></td></tr></table>
</div>
<table class="header_1_table"><tr><td class="header_11"></td><td class="header_121">
<ul><li class="header_121_a" id="hmenu_bbs" onmouseover="selectMenu(this.id)"><a href="#">论坛功能</a></li><li class="header_121_a" id="hmenu_member" onmouseover="selectMenu(this.id)"><a href="#">个人中心</a></li>{$forumstr}<li class="header_121_a" id="hmenu_template" onmouseover="selectMenu(this.id)"><a href="#">模板</a></li>{$plugins_menu}</ul>
</td>
<td class="header_13"></td></tr></table>

<table class="header_2_table"><tr><td class="header_21"></td>
<td class="header_22" id="secmenu">
<span id="sec_hmenu_bbs" style="display:none;"><ul><li><a href="search.php?action=new">今日新帖</a></li><li><a href="search.php?action=good">精华帖子</a></li><li><a href="search.php">论坛搜索</a></li><li><a href="userlist.php">会员列表</a></li></ul></span>
<span id="sec_hmenu_member" style="display:none;"><ul><li><a href="member.php?action=pic">我的头像</a></li><li><a href="member.php?action=details">个人资料</a></li><li><a href="member.php?action=password">密码设置</a></li><li><a href="member.php?action=msg">站内短信</a></li><li><a href="member.php?action=group">我的用户组/积分</a></li><li><a href="member.php?action=mytopic">我发表的帖子</a></li><li><a href="member.php?action=replytopic">我参与的帖子</a></li></ul></span>
<span id="sec_hmenu_template" style="display:none;"><ul>{$tmp_str}</ul></span>
<span id="sec_hmenu_plugins" style="display:none;"><ul>{$plugins_str}</ul></span>
&nbsp;</td><td class="header_23"></td></tr></table>
<table class="header_3_table"><tr><td class="header_31"></td>
<td class="header_32 header_321"><input type="text" id="search_input" /></td>
<td class="header_32 header_322"><a href="#" onclick="getSearchLink()" id="search_btn"><img src="{$_SYS['TP']}/images/btn_search.gif" border="0" align="absmiddle" /></a></td>
<td class="header_32" align="right"><b>热搜：</b><a href="http://www.baidu.com/s?wd=6kbbs" target="_blank">6KBBS</a><a href="http://www.baidu.com/s?wd={$cache_settings['bbsname']}" target="_blank">{$cache_settings['bbsname']}</a></td>
</td><td class="header_33"></td></tr></table>
</div>
{$pluginscode}
<!--body container BEGIN--><div class="body_container">
<!--
EOT;
?>
